<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>表单添加编辑渲染</title>
<link rel="stylesheet" type="text/css" href="/Plug-in/ext/resources/css/ext-all.css" />
    <script type="text/javascript" src="/Plug-in/ext/adapter/ext/ext-base.js"></script>
    <script type="text/javascript" src="/Plug-in/ext/ext-all.js"></script><script type="text/javascript">
	Ext.BLANK_IMAGE_URL = '/Plug-in/ext/resources/images/default/s.gif';
	</script>
<link rel="stylesheet" type="text/css" href="../css/main.css" />
<script type="text/javascript" src="/Plug-in/fck/fckeditor.js"></script>
<script type="text/javascript" src="/Plug-in/kind/kindeditor.js"></script>
<style type="text/css">
.x-date-menu > ul{
display: inline;
}
.x-date-menu > ul li{
display: inline;
}
.hang {
	background: #D1DDEF;
	border-top:1px dotted #B5B8C8;
	border-bottom:1px dotted #B5B8C8;
}

</style>
<script language="javascript">
Ext.onReady(function(){
Ext.QuickTips.init();
Ext.form.Field.prototype.msgTarget = 'side';
var form = new Ext.form.FormPanel({
				renderTo:Ext.getBody(),
				bodyStyle:'padding:5px',
				labelWidth:55,
				border:false,
				autoScroll:true,
				labelAlign:'right',
				buttunAlign:'left',
				plain:true,
				frame:true,
        items:[{
        	xtype:'fieldset',
            title: '编辑',
            autoHeight:true,
            bodyStyle:'padding:10px;',
            layout:'form',
            items:[
            {
						xtype:'hidden',
			            name: 'id',
			            value:'9'
		    },{
						xtype:'hidden',
			            name: 'tid',
			            value:'14'
		    },{
						xtype:'hidden',
			            name: 'gid',
			            value:'127'
		    },{
						xtype:'hidden',
			            name: 'lg',
			            value:'zh'
		    },
            				{xtype:"textarea",id:'205',value:"<p>0,Rssssssssss<span style=\"color: #ff0000\">ssssssss</span>sssssssss<img alt=\"\" src=\"/plug-in/fck/editor/images/smiley/msn/tounge_smile.gif\" />sssssssssssssssss</p><p>&nbsp;</p><p>&nbsp;</p><p>ssss</p>",width:800,height:200,fieldLabel:'sssss',listeners:{focus:function(f){var myMask = new Ext.LoadMask(Ext.getBody(), {msg:'请等待'});myMask.show();var w=f.getSize();fckEditor = new FCKeditor('sssss') ;fckEditor.Height=200;fckEditor.Width=800;fckEditor.SkinPath = '/Plug-in/fck/editor/skins/silver/' ;fckEditor.BasePath = '/plug-in/fck/' ;fckEditor.Config['ToolbarStartExpanded'] = true;fckEditor.ReplaceTextarea() ;myMask.hide();}},name: 'sssss'}
            ,				{
							xtype: 'textfield',
							value:"&nbsp;wwwwwwwwwwwwwww",
							fieldLabel:'我的',
							grow:true,
							id:'204',
							width:'200px',
							
							
							
							name: 'subtitle'
							}
            ,				{
							xtype: 'textfield',
							value:"<p>wwww<span style=\"",
							fieldLabel:'姓名',
							grow:true,
							id:'201',
							width:'580px',
							
							
							
							name: 'title'
							}
            ,				{
							xtype: 'textfield',
							value:"4",
							fieldLabel:'你',
							grow:true,
							id:'198',
							width:'400px',
							
							
							
							name: 'sortid'
							}
							,				{xtype:"textarea",id:'content',value:"<p>d41d8cd</p>>98f0<img alt=\"\" src=\"/plug-in/fck/editor/images/smiley/msn/teeth_smile.gif\" />7e</p>",width:800,height:260,fieldLabel:'密码xcxcv',listeners:{render:function(f){try{KE.show({id : 'content',width :'800px',height : '260px',filterMode : false});}catch(err){};}},name: 'content'}
            ,				{
							xtype: 'textfield',
							value:"1273622400",
							fieldLabel:'发布时间',
							grow:true,
							id:'203',
							width:'300px',
							
							
							
							name: 'pubtime'
							}
            ,				{
							xtype: 'textfield',
							value:"",
							fieldLabel:' 人人',
							grow:true,
							id:'199',
							width:'300px',
							
							
							
							name: 'cataid'
							}
            ,				{
							xtype: 'textfield',
							fieldLabel:'幻灯',
							inputType: 'file',
							id:'207',
							width:'150',
							
							name: 'hd'
							},{html:'<div style="float:left;width:300px;" align=center><a href="#"><img src="/uplods/pic/"></a></div>'}
            ,				{xtype: 'textarea',value:"zh",fieldLabel:'我多语言',grow:true,id:'200',width:'300px',name: 'lg'}
            ,				{
							xtype: 'textfield',
							value:"/uploads/2010-05-12/",
							fieldLabel:'上传12',
							grow:true,
							id:'206',
							width:'300px',
							
							
							
							name: 'pic1'
							}
                        ]
        }],
		buttons: [{
			xtype:'button',
            text: '保存',
            handler:function (){
								if(form.form.isValid()){
								try{var fckobj_temp = FCKeditorAPI.GetInstance('sssss');
										 fckobj_temp.UpdateLinkedField();}catch(err){
														};KE.util.setData('content');
								form.form.doAction('submit',{
									url:'i.php',
									method:'POST',
									params:{op:'save'},
									waitMsg:'正在提交....',
									success:function(form,action){
											if (action.result.msg=='ok') {
												Ext.Msg.confirm('提示','成功!是否关闭本窗口?',function(a){
													if(a=='yes'){
													 parent.gridrefresh();
													parent.Ext.getCmp('adddata14').close();
													}
												});

											} else {
												Ext.Msg.alert('提示',action.result.msg);
												Ext.get('username').select();
											}
									 }
									 ,
									 //提交失败的回调函数
									 failure:function(){
											Ext.Msg.alert('错误','数据提交错误！');
									 }
								})};
							}
        },{
        	xtype:'button',
            text: '取消'
        }]


});
});
</script>
</head>
<body>
</body>
</html>